package com.jecy.service.impl;

import com.jecy.dao.UserDao;
import com.jecy.domain.User;
import com.jecy.service.UserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * Created by huijun on 16/10/21.
 */
@Service("userService")
public class UserServiceImpl implements UserService {

    @Autowired
    private UserDao userDao;
    @Override
    public void inserUser(User user) {
        userDao.insert(user);
    }

    @Override
    public User queryUserById(Integer id) {
        return userDao.selectByPrimaryKey(id);
    }
}
